package com.project.service.base.ehcahe;

/**
 * 功能：缓存验证码
 *
 * Created by TAO on 2016/3/25.
 */
public interface EhcacheService {

    //==========验证码==============

    //添加验证码到cache
    void addCaptcha(String key, String captcha);

    //通过手机号从cache获取验证码
    String getCaptchaValueByMobile(String mobile);

    //通过邮箱从cache获取验证码
    String getCaptchaValueByEmail(String email);

    //通过用户名从cache获取验证码
    String getCaptchaValueByUsername(String username);

    //删除 验证码
    void removeCaptcha(String key);

}
